import { defineStore } from "pinia";

export const productListStore = defineStore("productListStoreId1", () => {
    const detailData = ref([
        {
            type: "text",
            prop: "channelMerchantType",
            name: "渠道商类型",
            value: null
        },
    ])
    const tableProp = reactive(
        {
            name: "productList1",
            propsList: [
                {
                    prop: "productCode",
                    label: "产品编码",
                    type: 'normal',
                    minWidth: '100px',
                    hidden: true,
                },
                {
                    prop: "productName",
                    label: "产品名称",
                    type: 'normal',
                    minWidth: '240px',
                    hidden: true,
                },
                {
                    prop: "productTitle",
                    label: "产品标题",
                    type: 'normal',
                    minWidth: '240px',
                    hidden: true,
                },
                {
                    prop: "productSubTitle",
                    label: "产品副标题",
                    type: 'normal',
                    minWidth: '240px',
                    hidden: true,
                },
                {
                    prop: "productType",
                    label: "产品类型",
                    type: 'normal',
                    minWidth: '120px',
                    hidden: true,
                },
                {
                    prop: "productCategoryName",
                    label: "产品大类",
                    type: 'normal',
                    minWidth: '140px',
                    hidden: true,
                },
                {
                    type: "normal",
                    prop: "supplierName",
                    label: "供应商名称",
                    minWidth: '270px',
                    hidden: true,
                },
                {
                    type: "custom",
                    prop: "supplierCode",
                    slotName: 'supplier',
                    label: "供应商编码",
                    minWidth: '200px',
                    hidden: true,
                },
                {
                    type: "normal",
                    prop: "supplierKey",
                    label: "供应商Key",
                    minWidth: '120px',
                    hidden: true,
                },
                // {
                //     type: "normal",
                //     prop: "supplierProductCode",
                //     label: "供应商产品编码",
                //     minWidth: '270px',
                //     hidden: true,
                // },
                {
                    type: "image",
                    prop: "intro",
                    label: "产品banner",
                    minWidth: '100px',
                    hidden: true,
                },
                // {
                //     prop: "listingTime",
                //     label: "上架时间",
                //     type: 'normal',
                //     width: '165px',
                //     hidden: true,
                // },
                // {
                //     prop: "delistingTime",
                //     label: "下架时间",
                //     type: 'normal',
                //     width: '165px',
                //     hidden: true,
                // },
                {
                    prop: "isp",
                    label: "运营商",
                    type: "custom",
                    slotName:"isp",
                    minWidth: '120px',
                    hidden: true,
                },
       
                {
                    prop: "supplierExtInfo",
                    label: "供应商扩展信息",
                    type: 'other',
                    minWidth: '150px',
                    hidden: true,
                },
                {
                    prop: "isShow",
                    label: "是否展示",
                    type: 'custom',
                    slotName: 'isShow',
                    minWidth: '70px',
                    hidden: true,
                },
      
                {
                    prop: "isStatistics",
                    label: "是否统计",
                    type: 'custom',
                    slotName: 'isStatistics',
                    width: '70px',
                    hidden: true,
                },
   
                {
                    type: 'handle',
                    label: '操作',
                    minWidth: '200px',
                    btnType: ' link',
                    slotName: 'handle',
                    hidden: true,
                }
            ]
    })

    return {
        detailData, tableProp
    }
})